package xyz.heyaoshare.core.controller.system.role.vo.req;

import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotBlank;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import java.io.Serial;
import java.io.Serializable;

import static io.swagger.v3.oas.annotations.media.Schema.RequiredMode.REQUIRED;

/**
 * 新增角色请求对象
 * @author YueHe
 * @version 0.0.1
 * @since 2025/5/9 下午4:01
 */
@Data
@Schema(description = "新增角色请求对象")
public class RoleInsertReqVO implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    @Length(max = 50, message = "角色名称长度不能超过{max}字符")
    @NotBlank(message = "角色名称不能为空")
    @Schema(description = "角色名称", requiredMode = REQUIRED)
    private String name;

    @Length(max = 50, message = "角色编码长度不能超过{max}字符")
    @NotBlank(message = "角色名称不能为空")
    @Schema(description = "角色编码", requiredMode = REQUIRED)
    private String code;

    @Length(max = 300, message = "备注长度不能超过{max}字符")
    @Schema(description = "备注")
    private String remark;

}